{include file="public/header" /}
<style type="text/css">
    #des, #des input {
        width: 40px;
        text-align: center;
    }

    #id {
        width: 78px;
    }

    .bs-checkbox {
        width: 36px;
        height: 40px
    }

    .fixed-table-toolbar .columns, .fixed-table-toolbar .search {
        margin-left: 0px;
        margin-top: 0px
    }

    #title span {
        float: right;
    }

    .btn-active {
        background: #1ab394;
        color: #fff
    }
</style>
<body class="gray-bg">
<div class="wrapper wrapper-content">
    <div class="ibox float-e-margins">
        {include file="public/tophead"}
        {include file="public/top" /}
        <div class="ibox-content">
            <div class="row row-lg">

                <div style="display:block;clear: both;"></div>
                <div class="fixed-table-toolbar">

                </div>
                <div class="example">
                    <form class="form-horizontal" method="post">
                        <table data-toggle="table" data-striped="false">
                            <thead>
                            <tr>
                                <th >id</th>
                                <th >类型名称</th>
                                <th>发布类型价格</th>
                                <th>是否显示</th>
                                <th>排序</th>
                                <th>管理</th>
                            </tr>
                            </thead>
                            <tbody>
                            {volist name="list" id="vo"}

                            <tr id="id{$vo.id}" class="gradeA footable-even category1">
                                <td class="categoryTitle">{$vo.id}</td>
                                <td class="categoryTitle">{:str_repeat("&nbsp;&nbsp;&nbsp;&nbsp;", $vo['depth'])}{gt name="$vo['depth']" value="0"}┠&nbsp;&nbsp;{/gt}{$vo.name}</td>
                                <td>{$vo.price}</td>
                                <td>{if $vo.is_show}显示{else}隐藏{/if}</td>
                                <td>{$vo.order}</td>

                                <td>
                                    <div class="btn-group">
                                        <div data-toggle="dropdown" class="btn btn-primary btn-xs dropdown-toggle">
                                            操作 <span class="caret"></span>
                                        </div>
                                        <ul class="dropdown-menu">
                                            <li>
                                                <a onClick="add('{:url('Content/typeAdd',['id'=>$vo['id'],'url'=>-1])}')">修改</a>
                                            </li>
                                            <li class="divider"></li>
                                            {if $vo.id>2}<li><a onclick="delById('content_type','{$vo.id}')">删除</a></li>{/if}
                                        </ul>
                                    </div>
                                </td>
                            </tr>
                            </tr>
                            {/volist}
                            </tbody>
                        </table>
                    </form>
                </div>
            </div>



        </div>
    </div>
</div>
{include file="public/footer" /}
{load href="__STYLE__/admin/plugins/bootstrap/bootstrap-table.min.css"}
{load href="__STYLE__/admin/plugins/bootstrap/bootstrap-table.min.js"}
{load href="__STYLE__/admin/plugins/bootstrap/bootstrap-table-zh-CN.min.js"}
<script type="text/javascript">
    function add(url) {
        layer.open({
            type: 2,
            title: '内容管理',
            shadeClose: false,
            shade: 0.2,
            area: ['80%', '95%'],
            skin: 'shangchuantup',
            // shift:-1,
            content: url,
        });
    }


</script>